package com.example.security.session;

import java.io.Serializable;


/***
 *
 * 自定义用户的session信息
 */
public class SysUserSession implements Serializable {

    private String userId;

    private String ip;

    private long requestTime;

    private long expireTime;

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }

    public long getRequestTime() {
        return requestTime;
    }

    public void setRequestTime(long requestTime) {
        this.requestTime = requestTime;
    }

    public long getExpireTime() {
        return expireTime;
    }

    public void setExpireTime(long expireTime) {
        this.expireTime = expireTime;
    }

    public SysUserSession() {
    }

    public SysUserSession(String userId) {
        this.userId = userId;
    }

    public SysUserSession(String userId, String ip, long expireTime) {
        this.userId = userId;
        this.ip = ip;
        this.requestTime = System.currentTimeMillis();
        this.expireTime = expireTime;
    }
}
